﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ERP.Domain.Products
{
    /// <summary>
    /// 产品表
    /// </summary>
    [Table("product")]
    public class Product : Audit
    {
        /// <summary>
        /// 自增主键ID
        /// </summary>
        [Key]
        public int Id { get; set; }

        /// <summary>
        /// 产品编号（GUID）
        /// </summary>
        public Guid ProductNumber { get; set; } = Guid.NewGuid();

        /// <summary>
        /// 产品名称
        /// </summary>
        public string ProductName { get; set; }

        /// <summary>
        /// 规格型号
        /// </summary>
        public string SpecificationModel { get; set; }

        /// <summary>
        /// 单位
        /// </summary>
        public string Unit { get; set; }

        /// <summary>
        /// 产品类型
        /// </summary>
        public string ProductType { get; set; }

        /// <summary>
        /// 产品属性
        /// </summary>
        public string ProductAttribute { get; set; }

        /// <summary>
        /// 产品分类
        /// </summary>
        public string ProductClassification { get; set; }

        /// <summary>
        /// 启用状态
        /// </summary>
        public bool? ActivationStatus { get; set; } = true;

        /// <summary>
        /// 有效日期
        /// </summary>
        public int? ValidDate { get; set; }

        /// <summary>
        /// 报警天数
        /// </summary>
        public int? AlarmDays { get; set; }

        /// <summary>
        /// 库存上限
        /// </summary>
        public int? MaximumInventoryLevel { get; set; }

        /// <summary>
        /// 库存下限
        /// </summary>
        public int? MinimumInventoryLevel { get; set; }

        /// <summary>
        /// 采购价格
        /// </summary>
        public decimal? PurchasePrice { get; set; }

        /// <summary>
        /// 销售价格
        /// </summary>
        public decimal? SalesPrice { get; set; }

        /// <summary>
        /// 备注
        /// </summary>
        public string Remarks { get; set; }

        /// <summary>
        /// 图片
        /// </summary>
        public string Image { get; set; }

        /// <summary>
        /// 附件
        /// </summary>
        public string Attachment { get; set; }

        /// <summary>
        /// 逻辑删除
        /// </summary>
        public bool? IsDelete { get; set; } = false;
    }
}
